﻿namespace Homework16
{
    internal class Program
    {/// <summary>
     /// 将第三题的文件移动到第二题的目录里
     /// </summary>
     /// <param name="args"></param>
        static void Main(string[] args)
        {
            string filePath = @"D:\CSharp2024\hello.txt";
            string rootPath = @"D:\CSharp2024\root";
            //构建目标文件的完整路径
            string destinationFilePath = Path.Combine(rootPath, 
                                                      Path.GetFileName(filePath));
            File.Move(filePath, destinationFilePath);
        }
    }
}
